package com.cskaoyan.wordmemorize.controller.admin;

import com.cskaoyan.wordmemorize.common.result.Result;
import com.cskaoyan.wordmemorize.dto.admin.OperateLogDTO;
import com.cskaoyan.wordmemorize.dto.admin.PageDTO;
import com.cskaoyan.wordmemorize.request.OperateLogPageRequest;
import com.cskaoyan.wordmemorize.service.AdminLogService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class AdminLogOperationController {
    @Autowired
    AdminLogService adminLogService;
    @GetMapping("admin/log/operation/list")
    public Result getOperateLogPage(OperateLogPageRequest request) {
        // 调用服务层方法获取操作日志列表
        PageDTO<OperateLogDTO> operateLogPage = adminLogService.getOperateLogPage(request);
        return Result.ok(operateLogPage);
    }
}
